package com.bjpowernode.service;


import com.bjpowernode.model.ext.BidLoanInfo;

import java.math.BigDecimal;
import java.util.List;

public interface BidInfoService {
    /**
     * 累计投资金额
     */
    BigDecimal querySumBidMoney();

    /**
     * 查询某个产品最近的3条投资记录
     */

    List<BidLoanInfo> queryRecentlyBidRecordByLoanId(Integer loanId);

    /**
     * 查询用户投资记录
     */
    List<BidLoanInfo> queryBidInfoByUid(Integer uid);


    /**
     * 投资
     * @param loanId 产品id
     * @param money 金额
     * @return
     */
    boolean invest(Integer loanId,BigDecimal money,Integer uid);
}
